package ma.ensao.evalmetrics.controller.metrics;

import java.io.File;
import java.io.IOException;

import ma.ensao.evalmetrics.model.MSF;
import ma.ensao.evalmetrics.util.javaProjects.MSFMetric;

/*
* Calcule 
* MSF represente la moyenne des methodes statiques (Static) par rapport a tous les methodes du systeme.
*/

public class MSFManager {
	private MSF msf=new MSF();
	double nmbre;
	private int nbMethods=0;
	
	public MSF read(File file) throws IOException {
		    MSFMetric mM = new MSFMetric(file);
		    setNmbre(mM.getMsf());
		    this.setNbMethods(mM.getNbMethods());
		    msf.setNmbre(getNmbre());
		    msf.setNbMethods(getNbMethods());
			return msf;
	}
	public MSF getMsf() {
		return msf;
	}
	public void setMsf(MSF msf) {
		this.msf = msf;
	}
	public double getNmbre() {
		return nmbre;
	}
	public void setNmbre(double nmbre) {
		this.nmbre = nmbre;
	}
	public int getNbMethods() {
		return nbMethods;
	}
	public void setNbMethods(int nbMethods) {
		this.nbMethods = nbMethods;
	}
}